<%@ page language="java" contentType="text/html; charset=UTF-8"
    pageEncoding="UTF-8"%>
<%@ taglib prefix="spring" uri="http://www.springframework.org/tags" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %>
<%@ taglib prefix="fn" uri="http://java.sun.com/jsp/jstl/functions"  %>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>


<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
	<title>SHIN SEUNG HUN</title>
	<link href="/resources/css/base.css" rel="stylesheet" type="text/css" />
	<script type="text/javascript" src="/resources/js/jquery.js"></script>
	<script type="text/javascript" src="/resources/js/jquery.ajax.js"></script>
	<script type="text/javascript">
		function goPurchaseForm() {
			var form = jQuery("#checkPurchaseForm");
			form.attr("action", "/purchaseForm.do");
			form.submit();
		}
		function goPurchase() {
			var form = jQuery("#checkPurchaseForm");
			var param = form.serialize();
			form.method = "POST";

			ajaxToJSON("/purchase.do", param, function(data) {
				jQuery(location).attr("href", "/purchaseResult.do");
			});
		}
	</script>
</head>
<body>
	<form id="checkPurchaseForm" method="POST" action="">
		<input type="hidden" name="onceTicket" value="${ticket.onceTicket}">
		<input type="hidden" name="twiceTicket" value="${ticket.twiceTicket}">
		<input type="hidden" name="price" value="${ticket.price}">
		<input type="hidden" name="userNameF" value="${ticket.userNameF}">
		<input type="hidden" name="userNameS" value="${ticket.userNameS}">
		<input type="hidden" name="hiraganaF" value="${ticket.hiraganaF}">
		<input type="hidden" name="hiraganaS" value="${ticket.hiraganaS}">
		<input type="hidden" name="postAdd" value="${ticket.postAdd}">
		<input type="hidden" name="postAdd1" value="${postAdd1}">
		<input type="hidden" name="postAdd2" value="${postAdd2}">
		<input type="hidden" name="addr1" value="${ticket.addr1}">
		<input type="hidden" name="addr2" value="${ticket.addr2}">
		<input type="hidden" name="addr3" value="${ticket.addr3}">
		<input type="hidden" name="phone" value="${ticket.phone}">
		<input type="hidden" name="phone1" value="${phone1}">
		<input type="hidden" name="phone2" value="${phone2}">
		<input type="hidden" name="phone3" value="${phone3}">
		<input type="hidden" name="userEmail" value="${ticket.userEmail}">
		<input type="hidden" name="userEmail1_1" value="${userEmail1_1}">
		<input type="hidden" name="userEmail1_2" value="${userEmail1_2}">
		<input type="hidden" name="userEmail2_1" value="${userEmail2_1}">
		<input type="hidden" name="userEmail2_2" value="${userEmail2_2}">
		<input type="hidden" name="userId" value="${ticket.userId}">
	</form>

	<div id="wrapper">
	<!-- container -->
	<div id="container_sub">
		<h1><img src="/resources/images/img_ticketing_top.jpg" alt="THE SHIN SEUNG HUN JAPAN LIVE 2013　～GREAT WAVE～" /></h1>
		<div class="content_sub">
			<h2>■入力情報確認</h2>
			<table class="tb_type2">
				<colgroup>
					<col width="140" /><col width="*" />
				</colgroup>
				<tr class="fst">
					<th>お名前</th>
					<td>${ticket.userNameF} ${ticket.userNameS}</td>
				</tr>
				<tr>
					<th>フリガナ</th>
					<td>${ticket.hiraganaF} ${ticket.hiraganaS}</td>
				</tr>
				<tr>
					<th>住所</th>
					<td>[郵便番号] :〒${ticket.postAdd}<br /><br />
						[都道府県] : ${ticket.addr1}<br /><br />
						[郡市区] : ${ticket.addr2}<br /><br />
						[その以後の住所] : ${ticket.addr3}

					</td>
				</tr>
				<tr>
					<th>携帯番号</th>
					<td>${ticket.phone}</td>
				</tr>
				<tr>
					<th>メールアドレス</th>
					<td>${ticket.userEmail}</td>
				</tr>
				<tr>
					<th>会員ＩＤ</th>
					<td>${ticket.userId}</td>
				</tr>
				<tr>
					<th>第1公演12月26日</th>
					<td>${ticket.onceTicket}枚</td>
				</tr>
				<tr>
					<th>第2公演12月27日</th>
					<td>${ticket.twiceTicket}枚</td>
				</tr>
				<tr>
					<th>合計</th>
					<td><fmt:formatNumber type="number" pattern="#,###" value="${ticket.price}" />円（税込）</td>
				</tr>
			</table>

			<p class="c mt50 point_r"><strong>内容に間違いがなければ「送信する」ボタンを押してください</strong></p>
			<div class="c mt40">
				<a href="javascript:goPurchaseForm();"><img src="/resources/images/img_btn5.gif" alt="前に戻る" class="mr17" /></a>
				<a href="javascript:goPurchase();"><img src="/resources/images/img_btn6.gif" alt="送信する" /></a>
			</div>
		</div><!--//content_sub-->

	</div><!--//container_sub-->

	<div class="footer"><c:import url="footer.jsp"/></div><!--//footer-->

</div>

</body>
</html>